package psnl.bingo.mr.demo4;

import org.apache.hadoop.io.WritableComparable;
import org.apache.hadoop.io.WritableComparator;

public class D4MapOutGroup extends WritableComparator {
    public D4MapOutGroup() {
        super(D4Line.class, true);
    }

    @Override
    public int compare(WritableComparable a, WritableComparable b) {
        D4Line aObj = (D4Line) a;
        D4Line bObj = (D4Line) b;
        return aObj.groupKey().compareTo(bObj.groupKey());
    }
}
